package cn.zxcoder.entity;


import io.swagger.annotations.Api;
import jdk.nashorn.internal.objects.annotations.Constructor;
import lombok.AllArgsConstructor;
import lombok.Data;
import lombok.NoArgsConstructor;
import org.springframework.stereotype.Component;

@Component
@Data
@Api(tags = "返回前端的信息")
public class Res {

    private boolean success;
    private String data;
    private String msg;
    private String token;

    public Res(boolean success, String data, String msg, String token) {
        this.success = success;
        this.data = data;
        this.msg = msg;
        this.token = token;
    }

    public Res(boolean success, String msg) {
        this.success = success;
        this.msg = msg;
    }

    public Res(boolean success, String data, String msg) {
        this.success = success;
        this.data = data;
        this.msg = msg;
    }

    public Res() {
    }

}
